import { request, METHOD } from '@/utils/request'

//组织列表
export async function orgLists(data) {
	return request(
		'http://hd.fenghuangkj.com/hidden/org/list',
		METHOD.GET,
		data
	)
}

//删除组织
export async function del(orgId) {
	return request(
		'http://hd.fenghuangkj.com/hidden/org/delete?orgId=' + orgId,
		METHOD.POST
	)
}

//编辑组织
export async function editOrg(data) {
	return request(
		'http://hd.fenghuangkj.com/hidden/org/update',
		METHOD.POST,
		data
	)
}

//添加组织
export async function addOrg(orgName) {
	return request(
		'http://hd.fenghuangkj.com/hidden/org/add?orgName=' + orgName,
		METHOD.POST
	)
}

//计划列表
export async function postPlanLists(data) {
	return request(
		'http://hd.fenghuangkj.com/hidden/record/task/list',
		METHOD.POST,
		data
	)
}


//计划删除
export async function postPlanDelete(data) {
	return request('http://hd.fenghuangkj.com/hidden/record/task/delete' + data, METHOD.POST)
}


//开启或关闭计划任务
export async function getPlanOpen(data) {
	return request('http://hd.fenghuangkj.com/hidden/record/task/open', METHOD.GET, data)
}

//添加计划任务  
export async function postPlanAdd(data) {
	return request('http://hd.fenghuangkj.com/hidden/record/task/add', METHOD.POST, data)
}

//编辑计划任务 
export async function postPlanUpdate(data) {
	return request('http://hd.fenghuangkj.com/hidden/record/task/update', METHOD.POST, data)
}

//计划任务详情 
export async function getPlanDetail(data) {
	return request('http://hd.fenghuangkj.com/hidden/record/task/detail', METHOD.GET, data)
}

